package org.dx.oho.entity;
import java.util.List;
import java.util.Objects;

/**
 * create by duanx 2020/11/9
 *@description： 店铺信息
 *@classname: Shop
 *@author: duanx
 *@date: 2020/11/9 14:44
 **/
public class Shop extends BaseEntity {
    /**
     *店铺ID
     */
    private Long shopId;
    /**
     * 所有者信息
     */
    private PersonInfo personInfo;
    /**
     * 所在区域
     */
    private Area area;
    /**
     * 店铺类别
     */
    private ShopCategory shopCategory;
    /**
     * 店铺名称
     */
    private String shopName;
    /**
     * 店铺描述
     */
    private String shopDesc;
    /**
     * 地址
     */
    private String shopAddr;
    /**
     * 电话
     */
    private String phone;
    /**
     * 店铺图片
     */
    private String shopImg;
    /**
     * 店铺优先级
     */
    private Integer priority;
    /**
     * 禁用状态
     */
    private Integer enableStatus;
    /**
     * 管理员审核或封禁信息
     */
    private String advice;

    /**
     * 店里的产品列表
     */
    private List<Product> products;
    /**
     * 图片列表
     */
    private List<ShopImg> shopImgs;

    public Long getShopId() {
        return shopId;
    }

    public void setShopId(Long shopId) {
        this.shopId = shopId;
    }

    public PersonInfo getPersonInfo() {
        return personInfo;
    }

    public void setPersonInfo(PersonInfo personInfo) {
        this.personInfo = personInfo;
    }

    public Area getArea() {
        return area;
    }

    public void setArea(Area area) {
        this.area = area;
    }

    public ShopCategory getShopCategory() {
        return shopCategory;
    }

    public void setShopCategory(ShopCategory shopCategory) {
        this.shopCategory = shopCategory;
    }

    public String getShopName() {
        return shopName;
    }

    public void setShopName(String shopName) {
        this.shopName = shopName;
    }

    public String getShopDesc() {
        return shopDesc;
    }

    public void setShopDesc(String shopDesc) {
        this.shopDesc = shopDesc;
    }

    public String getShopAddr() {
        return shopAddr;
    }

    public void setShopAddr(String shopAddr) {
        this.shopAddr = shopAddr;
    }

    public String getPhone() {
        return phone;
    }

    public void setPhone(String phone) {
        this.phone = phone;
    }

    public String getShopImg() {
        return shopImg;
    }

    public void setShopImg(String shopImg) {
        this.shopImg = shopImg;
    }

    public Integer getPriority() {
        return priority;
    }

    public void setPriority(Integer priority) {
        this.priority = priority;
    }

    public Integer getEnableStatus() {
        return enableStatus;
    }

    public void setEnableStatus(Integer enableStatus) {
        this.enableStatus = enableStatus;
    }

    public String getAdvice() {
        return advice;
    }

    public void setAdvice(String advice) {
        this.advice = advice;
    }

    public List<Product> getProducts() {
        return products;
    }

    public void setProducts(List<Product> products) {
        this.products = products;
    }

    public List<ShopImg> getShopImgs() {
        return shopImgs;
    }

    public void setShopImgs(List<ShopImg> shopImgs) {
        this.shopImgs = shopImgs;
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) {
            return true;
        }
        if (o == null || getClass() != o.getClass()) {
            return false;
        }
        Shop shop = (Shop) o;
        return Objects.equals(shopId, shop.shopId) &&
                Objects.equals(personInfo, shop.personInfo) &&
                Objects.equals(area, shop.area) &&
                Objects.equals(shopCategory, shop.shopCategory) &&
                Objects.equals(shopName, shop.shopName) &&
                Objects.equals(shopDesc, shop.shopDesc) &&
                Objects.equals(shopAddr, shop.shopAddr) &&
                Objects.equals(phone, shop.phone) &&
                Objects.equals(shopImg, shop.shopImg) &&
                Objects.equals(priority, shop.priority) &&
                Objects.equals(enableStatus, shop.enableStatus) &&
                Objects.equals(advice, shop.advice) &&
                Objects.equals(products, shop.products) &&
                Objects.equals(shopImgs, shop.shopImgs);
    }

    @Override
    public int hashCode() {
        return Objects.hash(shopId, personInfo, area, shopCategory, shopName, shopDesc, shopAddr, phone, shopImg, priority, enableStatus, advice, products, shopImgs);
    }

    @Override
    public String toString() {
        return "Shop{" +
                "shopId=" + shopId +
                ", personInfo=" + personInfo +
                ", area=" + area +
                ", shopCategory=" + shopCategory +
                ", shopName='" + shopName + '\'' +
                ", shopDesc='" + shopDesc + '\'' +
                ", shopAddr='" + shopAddr + '\'' +
                ", phone='" + phone + '\'' +
                ", shopImg='" + shopImg + '\'' +
                ", priority=" + priority +
                ", enableStatus=" + enableStatus +
                ", advice='" + advice + '\'' +
                ", products=" + products +
                ", shopImgList=" + shopImgs +
                '}';
    }
}
